package titt.server.service.listener;

import titt.util.io.pipe.PipeListener;

public class SuccessListener implements PipeListener {
	
	private final UpdateSuccess s;
	
	public SuccessListener(UpdateSuccess s) {
		this.s = s;
	}
	
	@Override
	public void onComplete(int total) {
		s.onSuccess(System.currentTimeMillis());
	}

	@Override
	public void onConnectionUpdate(int read, int total) {
		s.onSuccess(System.currentTimeMillis());
	}

	@Override
	public void onError() {
	}

	@Override
	public void onInitiate(int total) {
	}
}
